home *** CD-ROM | disk | FTP | other *** search
- #!/bin/sh
- #
- # ipfwadm-2.3.0 is used for 2.0.x kernels, while ipchains is used for newer
- # kernels. This shell script determines which kernel version is running and
- # calls ipfwadm-2.3.0 (if the kernel is 2.0.x), or ipfwadm-wrapper (if the
- # kernel is 2.1.x or 2.2.x). ipfwadm-wrapper is another script which
- # accepts ipfwadm syntax and makes the equivalent calls to ipchains.
-
- if [ "`uname -r | cut -d . -f 1-2`" = "2.0" ]; then # 2.0 kernel
- /sbin/ipfwadm-2.3.0 $*
- else # probably a newer kernel
- /sbin/ipfwadm-wrapper $*
- fi
-